What is @cspell/dict-en-common-misspellings?
@cspell/dict-en-common-misspellings is an npm package that provides a dictionary of common misspellings for use with the CSpell spell checker. It helps in identifying and correcting frequently misspelled words in English, enhancing the accuracy of spell-checking processes.
What are @cspell/dict-en-common-misspellings's main functionalities?
Integration with CSpell
This feature allows you to integrate the common misspellings dictionary with CSpell to check and correct text. The code sample demonstrates how to configure CSpell to use the 'en-common-misspellings' dictionary and check a text for common misspellings.
const cspell = require('cspell');
const settings = {
dictionaries: ['en', 'en-common-misspellings']
};
cspell.checkText('Ths is a smple txt with cmmon mispellings.', settings).then(result => {
console.log(result);
});
Custom Dictionary Usage
This feature allows you to use the common misspellings dictionary as a standalone dictionary for spell-checking. The code sample shows how to configure CSpell to use only the 'en-common-misspellings' dictionary to check a text.
const cspell = require('cspell');
const settings = {
dictionaries: ['en-common-misspellings']
};
cspell.checkText('Ths is a smple txt with cmmon mispellings.', settings).then(result => {
console.log(result);
});
Other packages similar to @cspell/dict-en-common-misspellings
cspell-dict-en_us
cspell-dict-en_us is a dictionary for American English words used with CSpell. It provides a comprehensive list of correctly spelled words in American English, but does not specifically focus on common misspellings like @cspell/dict-en-common-misspellings.
cspell-dict-en-gb
cspell-dict-en-gb is a dictionary for British English words used with CSpell. It offers a list of correctly spelled words in British English, similar to cspell-dict-en_us, but does not address common misspellings specifically.
CSpell Common English Misspellings Dictionary
Common English Misspellings dictionary for cspell.
This is a pre-built dictionary for use with CSpell.
Requirements
Installation
Global Install and add to CSpell global settings.
npm install -g @cspell/dict-en-common-misspellings
cspell link add @cspell/dict-en-common-misspellings
Uninstall from CSpell
cspell link remove @cspell/dict-en-common-misspellings
Manual Installation
Manual installation is useful if you want to include this dictionary as part of your CI/CD lint process.
npm i @cspell/dict-en-common-misspellings
The cspell-ext.json
file in this package should be added to the import section in your cspell.json
file.
{
"import": ["@cspell/dict-en-common-misspellings/cspell-ext.json"],
}
Reference
The source of this dictionary comes from:
Dictionary Development
See: How to Create a New Dictionary
License
CC BY-SA 4.0
Some packages may have other licenses included.
Brought to you by
Street Side Software